{% extends 'FortendBundle:Layout:wxLayout.html.twig' %}

{% block title %}预约骑马{% endblock %}

{% block css %}
    <link rel="stylesheet" href="{{ asset('static/css/style.css') }}">
{% endblock %}

{% block content %}
    <div class="weui-cells weui-cells_form">
        <div class="weui-cell">
            <div class="weui-cell__hd"><label class="weui-label">手机号</label></div>
            <div class="weui-cell__bd">
                <input class="weui-input" type="number" placeholder="请输入手机号">
            </div>
        </div>
        <div class="weui-cell weui-cell_vcode">
            <div class="weui-cell__hd"><label class="weui-label">验证码</label></div>
            <div class="weui-cell__bd">
                <input class="weui-input" type="number" placeholder="请输入验证码">
            </div>
            <div class="weui-cell__ft">
                <img class="weui-vcode-img" src="{{ path('api_public_generate_code') }}">
            </div>
        </div>

        <div class="weui-cell">
            <a href="javascript:;" class="weui-btn weui-btn_primary">提交</a>
        </div>
    </div>

    {% include '@Fortend/Wx/tabber.html.twig' %}
{% endblock %}

{% block js %}
    <script>
        $(function () {
            highlightAction(2);

            $('.weui-vcode-img').on('click', function() {
                var random = Math.random();
                $(this).attr("src", "{{ path('api_public_generate_code') }}?t="+random);
            })
        });
    </script>
{% endblock %}